#include<iostream>
#include<functional>

using namespace std;


int f(int x, int y) { return x - y; }
struct func
{
	int operator()(int x, int y)
	{
		return x - y;
	}
};
class Sub
{
public:
	int sub(int x, int y)
	{
		return x - y;
	}
};

//int main()
//{
//	size_t n = 0;
//	function<int(int, int)> sub = f;
//	function<int(int, int)> func2 = func();
//	function<int(int, int)> func3 = [](int x, int y) {return x - y; };
//	
//	Sub st;
//	function<int(int x, int y)> func4 = bind(sub, placeholders::_2, placeholders::_1);
//	function<int(int x, int y)> func5 = bind(&Sub::sub, Sub(), placeholders::_2, placeholders::_1);
//	function<int(int x, int y)> func6 = bind(&Sub::sub, &st, placeholders::_2, placeholders::_1);
//	function<int(int x, int y)> func7 = bind(&Sub::sub,st, placeholders::_2, placeholders::_1);
//
//	cout << func7(10, 5) << endl;
//
//	return 0;
//
//}

class Person
{
public:
	 ~Person() { cout << "~Person()" << endl; }
};
class Student : public Person
{
public:
	 ~Student() { cout << "~Student()" << endl; }
};


class Base
{
public:
	virtual void Func1()
	{
		cout << "Base::Func1()" << endl;
	}
	virtual void Func2()
	{
		cout << "Base::Func2()" << endl;
	}
	void Func3()
	{
		cout << "Base::Func3()" << endl;
	}
private:
	int _b = 1;
};

class Derive : public Base
{
public:
	virtual void Func1()
	{
		cout << "Derive::Func1()" << endl;
	}
private:
	int _d = 2;
};

int main()
{

	Base b;

	Derive de;

	return 0;

}